home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / graphics / dta21.zip / DTA.DOC < prev    next >
Text File  |  1994-04-23  |  29KB  |  763 lines

  1.                    DTA (Dave's .TGA Animation Program)
  2.                           Rel 2.1 (04/23/94)
  3.           Copyright (c) 1991, 1992, 1993, 1994 by David K. Mason
  4.  
  5.   DTA is a command-line utility for creating Autodesk Animator .FLI
  6.   and .FLC animation files from:
  7.  
  8.   o .TGA files as created by the POV-Ray and POLYRAY ray-tracers.
  9.   o .IMG files as created by the Vivid ray-tracer.
  10.   o .PCX files.
  11.   o .DIB or .BMP files
  12.   o .GIF files.
  13.   o Other .FLI or .FLC files.
  14.   o VistaPro .VAN animation files
  15.   o Presidio .ANI animation files
  16.  
  17.   DTA can also perform a wide range of post-processing functions
  18.   on image files including:
  19.  
  20.   o Create a single optimal 256-color palette from a series of
  21.     truecolor pictures, and then creating an Autodesk Animator .FLI
  22.     file out of them.
  23.   o Save the palette as a .MAP (PICLAB, FRACTINT) or .COL
  24.     (Autodesk Animator) palete file.
  25.   o Convert pictures to a bunch of different still image formats.
  26.   o Read in a palette file in either .COL or .MAP format
  27.     and animating a bunch of pictures using that palette.
  28.   o Arbitrary rotation.
  29.   o Scaling.
  30.   o Multi-layer compositing.
  31.   o Averaging images together for a variety of effects, including
  32.     simulated motion blur and red/blue 3D.
  33.   o And more.
  34.  
  35. ======================================================================
  36. **** IF YOU ARE HAVING MEMORY PROBLEMS WITH DTA, READ THIS ****
  37.  
  38. Real mode vs. Protected mode:
  39.  
  40.   DTA used to come in two varieties: a real mode version and
  41.   a protected mode version.  From now on there's only a
  42.   protected mode version.  There's no more DTAX.EXE.
  43.  
  44.   DTA will let you access up to 16MB of extended memory (either raw
  45.   or configured as XMS with HIMEM.SYS or QEMM386.SYS or whatever).
  46.   It requires at least 1 or 2 MB of RAM to run at all.
  47.  
  48.   Don't delete the files DPMI16BI.OVL, RTM.EXE, and DPMIINST.EXE.
  49.   These make up the protected mode drivers for Borland Pascal 7.0
  50.   (the compiler used to build DTA).  DTA won't run without them.
  51.  
  52. ======================================================================
  53. The Rules:
  54.  
  55.   Feel free to re-upload this program to other bulletin board
  56.   systems in its *original, unmodified* form.  You may not
  57.   repackage it with other programs.  You may not repackage it with
  58.   your own tutorial.  I feel like an idiot having to make these
  59.   demands, but I've been finding archives on BBSs going by
  60.   names like MORPHPAK.ZIP which are collections of DTA, my other
  61.   program DMorf, sometimes also Richard Godoeken's program
  62.   RMORPH, plus Trilobyte's PLAY.  That's not kosher.  I and those
  63.   other folks distributed our programs the way we did for
  64.   reasons.
  65.     Do not include this program on a disk along with any magazine,
  66.   book, hardware product, or other software product without my
  67.   permission.
  68.     If you place this program on an Internet FTP site, please drop
  69.   me a note (76546.1321@compuserve.com) so I'll know how to answer
  70.   when people ask me "Where can I find DTA on the net?"
  71.  
  72. ======================================================================
  73. Money matters:
  74.  
  75.   DTA is a shareware program.  If you think this program is worth
  76.   it, send some money or some computer hardware or something to:
  77.  
  78.     David K. Mason
  79.     P.O. Box 181015
  80.     Boston, MA 02118
  81.  
  82.   I think $35 is an appropriate amount, but feel free to send more
  83.   or less.
  84.  
  85. ======================================================================
  86. Blatant shameless plugs:
  87.  
  88.  Other shareware programs:
  89.  
  90.    o Dave's Morphing program (DMorf), the first shareware morphing
  91.      program for the PC.
  92.  
  93.    o Dave's Flic Viewer (DFV), an animation player that can
  94.      handle DTA's FLH and FLT files in addition to conventional
  95.      FLI and FLC files.  (no shareware registration required
  96.      for registered users of DTA or DMorf)
  97.  
  98.    o Dave's Self-Viewing Flic Builder (BUILDSV), which
  99.      converts flics into executable programs by appending a
  100.      copy of the flic to a special version of DFV.
  101.      (no shareware registration required for registered users
  102.      of DTA or DMorf)
  103.  
  104. ----------------------------------------------------------------------
  105.  
  106.   For more information on using DTA and related programs,
  107.   see my books:
  108.  
  109.     "Making Movies on Your PC" (by David K. Mason and Alexander
  110.   Enzmann, Waite Group Press, $34.95 USA, ISBN 1-878739-41-7)
  111.   covers the creation of 3D animation sequences using Polyray
  112.   and DTA.  The DTA reference info is up to date through
  113.   release 1.8g.
  114.  
  115.     "Morphing on Your PC" (by David K. Mason, Waite Group Press,
  116.   $29.95 USA, ISBN 1-878739-53-0) covers building animated
  117.   morph sequences with DMorf and DTA.  The DTA reference info
  118.   is up to date through release 2.0.
  119.  
  120. ======================================================================
  121. Syntax:
  122.  
  123.  Syntax: DTA (filenames) (options)
  124.  
  125. ======================================================================
  126. Input Formats:
  127.  
  128.   .TGA        Targa 8-,16-,24-,32-bit compressed/uncompressed.
  129.   .GIF        GIF (87a or 89a).
  130.   .PCX        PC Paintbrush 256-color or 24-bit PCX images.
  131.   .DIB/.BMP   Microsoft Windows device-independent bitmap files.
  132.   .IMG        Vivid raytracer 24-bit RLE output.
  133.   .FLI and
  134.   .FLC        Autodesk Animator/Animator Pro animation files.
  135.   .VAN        VRLI VistaPro 256-color animation files.
  136.   .ANI        Presidio PC Animate Plus animation files.
  137.   .RLE        MindImage 2 SIRDS run-length encoded depth
  138.               files.
  139.   .IFF,.LBM,
  140.   .ILB        Amiga IFF/ILBM pictures.
  141.  
  142.   .LZH        LHArc compressed archive containing files in the above
  143.               picture formats.
  144.   .ZIP        PKZIP compressed archive containing files in the above
  145.               picture formats.
  146.  
  147.   @script     Process all files listed in a text file called
  148.               "script.SCR".
  149.  
  150.  To specify a particular picture in an archive:
  151.    "ARCHIVE.ZIP:PICTURE.TGA".
  152.  To specify particular frames in an animation:
  153.    "ANIM.FLI:first[,last]".
  154.  
  155. ======================================================================
  156. Switches:
  157.  
  158.  (Filename options)
  159.  
  160.    /O(name)      Specify output filename
  161.    /FO[#[,#]]    Always save to the original filename
  162.  
  163.  
  164.  (Output format options)
  165.  
  166.    By default, DTA will create a flic (.FLI/.FLC/.FLH/.FLT) animation file,
  167.    Specify a different format with one of these switches:
  168.  
  169.    (default)   Create a .FLI animation file.
  170.  
  171.    /FT (.TGA)    /FB (.BMP)    /FM (.MAP palette)    /FR (MindImage .RLE)
  172.    /FG (.GIF)    /FD (.DIB)    /FC (.COL palette)    /FI (grayscale .TIF)
  173.    /FB (.PCX)                                        /FV (.VAN animation)
  174.  
  175.  (Output resolution options)
  176.  
  177.    By default, DTA will create output files with the same dimensions as
  178.    as the input pictures.  When creating an animation, it will use the
  179.    dimensions of the first input picture.
  180.  
  181.    This is sometimes undesirable, as when you''ve got multiple pictures
  182.    of different sizes, or when you''re compositing pictures.
  183.  
  184.    So, you can override this with one of these switches:
  185.  
  186.    /R#    specify output resolution:
  187.              (1) 320x200   (4) 320x480   (7) 640x400   (10) 1024x768
  188.              (2) 320x240   (5) 360x480   (8) 800x600   (12) 1280x1024
  189.              (3) 320x400   (6) 640x480
  190.  
  191.    /R#,#  specify resolution exactly
  192.  
  193.  (Misc. output options)
  194.  
  195.    /B##   bits per pixel.  Legal values and *defaults*:
  196.             TGA: 8 16 *24* 32     flics: *8*/16/24
  197.             PCX: *8* 24           all others: 8
  198.             BMP/DIB: 8 *24*
  199.  
  200.  (Flic output options)
  201.  
  202.     /FLX   build a Tempra .FLX file instead of default .FLH (16-bit
  203.            only)
  204.     /FLC   build .FLC even when the size is 320x200 (8-bit only)
  205.     /P     ping-pong
  206.     /Snnn  specify display speed of animation; default=0
  207.     /TO#   (flic tolerance) causes DTA to ignore pixel differences
  208.            between frames when the distance in color-space is less
  209.            than or equal to a value that you supply.
  210.     /TX#   Include a complete, no-tolerance frame once every
  211.            # frames.  (use only in conjunction with /TO)
  212.            (/TO and /TX work only with FLT and FLH files)
  213.  
  214.  (.GIF output options)
  215.  
  216.     /IG    interlace .GIF files
  217.  
  218.  (.TGA output options)
  219.  
  220.     /NC    don''t compress .TGA files
  221.     /BU    save .TGA files bottom-up instead of top-down
  222.  
  223.  (Palette options for colormapped output)
  224.  
  225.     /G           Use greyscale instead of a palette.
  226.     /G32         Use 32-level greyscale instead of a palette.
  227.                  (there's also a /G128, /G64, /G32, /G16, /G8,
  228.                  and /G4)
  229.                    /G represents a 256-level grayscale except when
  230.                  the output format is a 320x200 .FLI file, when it
  231.                  represents a 64-level grayscale.  That's because
  232.                  .FLI won't support higher than 64 shades.
  233.                  /G128 represents a 128-level grayscale, /G64 a
  234.                  64-level grayscale, etc.
  235.                    Most VGA and SVGA monitors can only display 64
  236.                  shades of gray, so it's wasteful to use more than
  237.                  that if your picture will only be displayed on a
  238.                  monitor.  Some laptop VGA displays can only display
  239.                  32 shades.
  240.                    If you're going to be printing your image or using
  241.                  it as a bump map or height field with a rendering
  242.                  program, then the more shades the better.
  243.     /332         Use 3/3/2 palette.
  244.     /Upalname    Use existing .MAP or .COL file for palette.
  245.     /M#          Set maximum colors.
  246.     /MN          Do NOT remap colormapped input.
  247.     /PO          Force single optimal palette generation even when
  248.                  creating GIF files.
  249.     /C#          Scan only one frame per # for palette.
  250.  
  251.  (Dithering options)
  252.     /DF          dither with Floyd-Steinberg filter
  253.     /DS          dither with Sierra Lite filter
  254.     /DO[#]       Ordered dither; digit represents dither strength
  255.     /DR[#]       Random noise dither
  256.  
  257.  (Frame averaging options)
  258.  
  259.     /A[#|A]  Average <number> TGAs per output frame (A=All).
  260.     /T[#|A]  Trail   <number> TGAs per output frame (A=All).
  261.     /X[num]  eXpand <number>. Create and insert <number> averaged.
  262.              frames between each pair of regular frames.
  263.     /WF      weight of first frame (default=1)
  264.     /WI      weight increment (default=0)
  265.  
  266.  (Composition options)
  267.  
  268.     /L             Separates output layers.  Picture files specified
  269.                    in later layers get overlayed on top of previous
  270.                    layers.  If the overlayed pictures contain
  271.                    transparency information (32-bit TGA files only),
  272.                    then the pictures underneath will show through.
  273.     /CK#,#,#       Chroma-key, to make all occurrences of a color
  274.                    transparent for compositing.  The three numbers
  275.                    represent the red,green, and blue components
  276.                    of the key color.
  277.     /CI#,#,#       inverse chroma-key
  278.     /CT#           Chroma-key tolerance.  Specifies how close to the
  279.                    key color a pixel has to be to make it transparent.
  280.     /CC#,#,#,#     chroma-key color... specify an RGBa value to replace
  281.                    chroma-keyed pixels with (default=0,0,0,0)
  282.     /ALPHA, /RED,  make a grayscale image from a picture''s alpha channel,
  283.     /GREEN, /BLUE  or from one of the color channels.
  284.  
  285.  (Geometrical transformation options)
  286.  
  287.     /CL#,#[,#,#]   Clip the input picture.  The first two numbers
  288.                    specify the top-left, and the other two numbers
  289.                    control the width and depth.
  290.     /CLP#,#[,#,#]  clip from top-left (after scaling)
  291.     /LOC#,#[,#]    specify where to place image (default is 0,0)
  292.                    The final number specifies time
  293.     /LT            Make /LOC base vertical coords from the top edge
  294.                    instead of the center.
  295.     /LB            Make /LOC base vertical coords from the bottom edge.
  296.     /LL            Make /LOC base horizontal coords from the left edge
  297.                    instead of the center
  298.     /LR            Make /LOC base horizontal coords from the right edge
  299.     /ROT#[,#]      rotation... first number represents angle, second
  300.                    is for time
  301.     /SC[#,#]       rescale pictures to screen res. or specified size
  302.     /SCF[#,#]      fast, but dumb, rescale
  303.  
  304.  (Other options that I don''t know how to classify)
  305.  
  306.     /K#            Use only one frame per # picture files.  Skip the
  307.                    rest.
  308.     /I[#]          process a total of # picture files
  309.     /GA#           Gamma-correct picture.  Try specifying a number
  310.                    between 1.0 and 2.0 to brighten, between 0.5 and
  311.                    1.0 to darken.
  312.     /INV[R,G,B,A]  invert colors or individual color channel
  313.  
  314.  
  315. ======================================================================
  316. Scripts:
  317.  
  318.   As I mentioned earlier, you tell DTA to process all the files
  319.   listed in a text file by specifying the name of the text file
  320.   preceded by a "@".
  321.     A script file can contain as many file specifications
  322.   as you want.  It can also contain any of the above-mentioned
  323.   switches.  Each must be on a line of its own.
  324.     Here's an example script called test.scr:
  325.  
  326.      back.tga
  327.      /l
  328.      *.tga
  329.      /a2
  330.      /sc640,480
  331.      /l
  332.      signat.gif
  333.      /lr
  334.      /lb
  335.      /fo2
  336.  
  337.     Typing "dta @test" in this case would cause DTA to perform
  338.   exactly the same as if you instead typed:
  339.  
  340.      dta back.gif /l *.tga /a2 /sc640,480 /l signat.gif /lr /lb /fo2
  341.  
  342.     Scripts can come in handy if
  343.  
  344.     (a) your command is just getting too darn long and
  345.   complicated to fit on a DOS command line.  A script can
  346.   be as long as you want.
  347.     (b) you have to use the same command over and over
  348.   again.  Why remember all that stuff or use a crib sheet
  349.   when you can just put it all in a script just once
  350.   and then use it over and over.
  351.  
  352.     You can also use a script in addition to other filenames
  353.   and switches:
  354.  
  355.     Say you had a script file called whirl.scr that looked like
  356.   this:
  357.  
  358.      /l
  359.      logo.gif
  360.      /rot0,0
  361.      /rot360,100
  362.      /ch0,0,0
  363.      /loc400,350
  364.  
  365.     then instead of typing
  366.  
  367.      dta x*.tga /l logo.gif /rot0,0 /rot360,100 /ch0,0,0 /loc400,350
  368.  
  369.     you could just type:
  370.  
  371.      dta x*.tga @whirl
  372.  
  373. ======================================================================
  374. Revision History:
  375.  
  376.   (see WHATSNEW.DTA)
  377.  
  378. ======================================================================
  379. Averaging/Trailing/Expansion modes (/A /T /X switches) examples:
  380.  
  381.   Averaging 5 input pictures with "/A2" option:
  382.  
  383.     Average:    To produce:
  384.  
  385.     file 1      frame 1
  386.     file 2
  387.  
  388.     file 3      frame 2
  389.     file 4
  390.  
  391.     file 5      frame 3
  392.     file 1
  393.  
  394.   Trailing 4 input pictures with "/T2" option:
  395.  
  396.     Average:    To produce:
  397.  
  398.     file 1      frame 1
  399.     file 2
  400.  
  401.     file 2      frame 2
  402.     file 3
  403.  
  404.     file 3      frame 3
  405.     file 4
  406.  
  407.     file 4     frame 4
  408.     file 1
  409.  
  410.   Trailing 5 input pictures with "/T3" option:
  411.  
  412.     Average:    To produce:
  413.  
  414.     file 1      frame 1
  415.     file 2
  416.     file 3
  417.  
  418.     file 2      frame 2
  419.     file 3
  420.     file 4
  421.  
  422.     file 3      frame 3
  423.     file 4
  424.     file 1
  425.  
  426.     file 4      frame 4
  427.     file 5
  428.     file 1
  429.  
  430.     file 5      frame 5
  431.     file 1
  432.     file 2
  433.  
  434.   Expanding 2 input pictures with "/X1" option:
  435.  
  436.     frame 1 =  (100% of FILE 1  ) + (  0% of FILE 2  )
  437.     frame 2 =  ( 50% of FILE 1  ) + ( 50% of FILE 2  )
  438.     frame 3 =  (  0% of FILE 1  ) + (100% of FILE 2  )
  439.  
  440.   Expanding 2 input pictures with /X2" option:
  441.  
  442.     frame 1 =  (100% of FILE 1  ) + (  0% of FILE 2  )
  443.     frame 2 =  ( 66% of FILE 1  ) + ( 33% of FILE 2  )
  444.     frame 3 =  ( 33% of FILE 1  ) + ( 66% of FILE 2  )
  445.     frame 4 =  (  0% of FILE 1  ) + (100% of FILE 2  )
  446.  
  447. ======================================================================
  448. Miscellaneous examples:
  449.  
  450. (Note: some of these examples, especially the ones near the
  451. very end, are ridiculous... you'd never actually have a use for
  452. exactly those combinations of switches.  They're there to
  453. give you an idea of what weirdness you can achieve by
  454. mixing and matching DTA's assorted abilities.)
  455.  
  456. (Note 2: This section could use some more examples... if
  457. you've got a favorite combination, let me know and I'll add
  458. it to this doc.)
  459.  
  460. ----------------------------------------------------------------------
  461. DTA ROCKET*.TGA
  462.  
  463. Create an 8-bit (256-color) flic file (.FLI or .FLC) from a bunch
  464. of .TGA files.
  465.  
  466. ----------------------------------------------------------------------
  467. DTA ROCKET*.TGA /B16
  468.  
  469. Create an 16-bit flic file (.FLH) from a bunch of .TGA files.
  470.  
  471. ----------------------------------------------------------------------
  472. DTA ROCKET*.TGA /B24
  473.  
  474. Create an 24-bit flic file (.FLT) from a bunch of .TGA files.
  475.  
  476. ----------------------------------------------------------------------
  477. DTA ROCKET*.TGA /FC /OROCKET
  478.  
  479. Make a palette for all .TGA files starting with "ROCKET".
  480. Output the palette to an Animator palette file called "ROCKET.COL".
  481.  
  482. ----------------------------------------------------------------------
  483. DTA SKY.GIF /L BEFORE.TGA MORF*.TGA AFTER.TGA
  484.  
  485. Build a multilayer flic.  SKY.GIF gets put in the background, and
  486. the pictures FIRST.TGA, a bunch of TGAs beginning with the string
  487. MORF, and LAST.TGA get superimposed over it.  SKY.GIF shows through
  488. any parts of the other pictures which are transparent.
  489. (32-bit TGA files can contain a transparency value for each
  490. pixel called an "alpha channel".)
  491.  
  492. This example assumes that the pictures BEFORE.TGA and AFTER.TGA
  493. had transparency added to them with my other program, DMorf
  494. (Rel. 1.1 or higher), and that the MORF*.TGA files are morphed
  495. pictures built with DMorf.
  496.  
  497. ----------------------------------------------------------------------
  498. DTA PIC1 PIC2 PIC3 /FM /OXYZ
  499.  
  500. Make a palette for .TGA files "PIC1.TGA", "PIC2.TGA", and "PIC3.TGA"
  501. Output the palette to a PICLAB palette file called "XYZ.MAP".
  502.  
  503. ----------------------------------------------------------------------
  504. DTA ROCKET* /OROCKET /DF
  505.  
  506. Make input from all .TGA files beginning with "ROCKET".
  507. Output to an animation file called "ROCKET.FLI".
  508. Dither the frames with Floyd-Steinberg error-diffusion.
  509.  
  510. ----------------------------------------------------------------------
  511. DTA ROCKET* /G /DO2 /P
  512.  
  513. Make input from all .TGA files beginning with "ROCKET".
  514. Map colors to grayscale.
  515. Dither, using ordered dither strength 2.
  516. Ping-pong it.
  517. Output to an animation with the default name of "ANIM.FLI"
  518.  
  519. ----------------------------------------------------------------------
  520. DTA ROCKET
  521.  
  522. Make input from ROCKET.TGA.
  523. Output to an animation with the default name of "ANIM.FLI".
  524.  
  525. ----------------------------------------------------------------------
  526. DTA @WING2.LST /S10 /OWING2.FLI
  527.  
  528. Make input from files listed in a text file called "WING2.LST".
  529. Set playback speed to "10".
  530. Output to an animation with the name of "WING2.FLI".
  531.  
  532. ----------------------------------------------------------------------
  533. DTA BBB*.TGA AAA*.TGA /UPAL1.COL /UPAL2.MAP /OFRED
  534.  
  535. Make input from all .TGA files whose name begins with "BBB", and "AAA".
  536. NOTE:
  537.     The "BBB" files will appear in the animation before the "AAA" files.
  538.     The "BBB" files will be sorted alphabetically, and so will the
  539.     "AAA" files, but separately.
  540. Read in an Animator palette file called "PAL1.COL", and merge it with
  541.     a Piclab palette file called "PAL2.MAP".
  542.     Use this combined palette for the animation.
  543. Output to an animation with the name of "FRED.FLI".
  544.  
  545. ----------------------------------------------------------------------
  546. DTA *.TGA /FG
  547.  
  548. Make .GIFs from all .TGAs in the current directory.
  549.  
  550. ----------------------------------------------------------------------
  551. DTA SOMBRERO /FG /DR2 /G
  552.  
  553. Make a dithered grayscale .GIF from a file called SOMBRERO.TGA.
  554.  
  555. ----------------------------------------------------------------------
  556. DTA /CHR LEFT*.TGA /GA0.8 /CHB RIGHT*.TGA
  557.  
  558. Make a red/blue 3D .FLI file.
  559. Use the .TGA files beginning with "LEFT" as the red component
  560. And the ones beginning with "RGHT" as the blue component.
  561. NOTE: For this to work right, there must be an equal number of
  562.    "LEFT" and "RGHT" .TGAs.
  563. (the /ga is to adjust the brightness of the red component
  564. so it doesn't drown out the blues.  Some experimentation
  565. may be necessary to get the balance just right... if
  566. somebody comes up with a better brightness combination,
  567. let me know and I'll put it right here in the doc.)
  568. Output to an animation with the default filename of "ANIM.FLI"
  569.  
  570. ----------------------------------------------------------------------
  571. DTA XXX*.TGA /L YYY*.TGA /CHA ZZZ*.TGA
  572.  
  573. This is a fun one...  Create an animation with three sets
  574. of pictures.  The ones called XXX*.TGA are the background,
  575. and the YYY*.TGA pictures are the foreground.  But,
  576. the ZZZ*.TGA pictures are used for the alpha channel of
  577. the foreground, dictating which parts of the YYY pictures
  578. will be transparent and how much (dark parts of ZZZ will
  579. make YYY very transparent, while bright parts will be less
  580. so.
  581.  
  582. ----------------------------------------------------------------------
  583. DTA XXX* /FTYY /AA
  584.  
  585. Make input from .TGAs beginning with "XXX".
  586. Average all files.
  587. Output to a new Targa file called "YY.TGA".
  588.  
  589. ----------------------------------------------------------------------
  590. DTA XXX*.TGA /T3 /DO3 /OZZZ
  591.  
  592. Make input from all .TGA files beginning with "XXX"
  593. Trail 3 frames.
  594. Use ordered dithering, strength 3.
  595. Output an animation called "ZZZ.FLI"
  596.  
  597. ----------------------------------------------------------------------
  598. DTA XXX*.TGA /X3
  599.  
  600. Make input from all .TGA files beginning with "XXX"
  601. Expand 3.  Assuming 5 .TGA input files, this would create a 15 frame
  602. animation.
  603. Output an animation called "ANIM.FLI"
  604.  
  605. ----------------------------------------------------------------------
  606. DTA *.GIF
  607.  
  608. Creates a file called ANIM.FLI or ANIM.FLC from all .GIF files in the
  609. current directory.  (The extension depends on the resolution of the
  610. first picture.  If it's 320 by 200, then DTA will create a .FLI
  611. file.  Otherwise, it'll create a .FLC.
  612.  
  613. ----------------------------------------------------------------------
  614. DTA *.TGA /K2 /C2
  615.  
  616. Assuming 60 .TGA files, create a flic containing only 30 frames.
  617. Generate the palette from only 15 frames.
  618.  
  619. ----------------------------------------------------------------------
  620. DTA *.GIF /R320,200 /SC
  621.  
  622. Create a flic from a bunch of GIF files, set the screen size
  623. to 320 by 200, and rescale all the images to the screen size.
  624.  
  625. ----------------------------------------------------------------------
  626. DTA *.TGA /R6 /SC320,240
  627.  
  628. Create a 640x480 FLC file from a bunch of TGA files.  Rescale each
  629. picture so that the width is depth is 240, but leave the width alone.
  630. This one is useful when you want to turn a bunch of 320x200
  631. pictures into a 640x480 flic... because 320x200 screens use a
  632. different aspect ratio than 640x480.  320x200 pictures look a
  633. bit squat when you display them in 640x480 mode, but 320x240 looks
  634. correct.
  635.  
  636. ----------------------------------------------------------------------
  637. DTA FLIC1.FLI FLIC2.FLI /OFLIC3
  638.  
  639. Create a new flic by appending two existing flics.  Unlike my old
  640. FLAP program, DTA will create a new palette.
  641.  
  642. ----------------------------------------------------------------------
  643. DTA FLIC.FLI /FG /NM
  644.  
  645. Create GIF files from the frames in FLIC.FLI.  The /NM tells DTA
  646. *not* to generate an optimized palette.  That would be a waste of
  647. time, since a FLIC file usually contains an optimized palette.
  648.  
  649. ----------------------------------------------------------------------
  650. DTA FLIC.FLI /SC120,100 /ROT90 /ONEWFLIC /R1 /NM
  651.  
  652. Read an existing flic, scale each of the frames to a 100x100
  653. square, rotate the result 90 degrees to the right, and
  654. create a new flic.  (The /R1 tells DTA to make a 320x200
  655. .FLI file instead of a 100x120 .FLC file.  The little 100x120
  656. square gets placed in the middle of the screen.
  657.  
  658. ----------------------------------------------------------------------
  659. DTA FLIC.FLI /SC100,100 /ROT0,0 /ROT360,100 /ONEWFLIC /R1
  660.  
  661. This one is much like the last example, but a bit funkier.
  662. The first frame (0%) will be rotated 0 degrees (not at all).
  663. The last frame (100%) will be rotated 360 degrees (a complete
  664. rotation).  The frames in between will be rotated in imcrements
  665. between 0 and 360 degrees. (If you had 362 frames in the
  666. animation, then the second frame would be rotated 1 degree,
  667. the second 2 degrees, etc.)
  668.   Note we did *not* use the /NM switch to turn off palette
  669. optimization.  Scaling and rotation *require* that the palette
  670. be remapped because the processes create new colors.
  671. On the other hand, fast scaling (/SCF) and 90-degree
  672. rotations do not require an optimized palette.
  673.  
  674. ----------------------------------------------------------------------
  675. DTA FLIC.FLI /SC100,100 /ROT0,0 /ROT180,66.666 /ROT360,100 /ONF /R1
  676.  
  677. Not quite the same as the last example.  Instead of rotating
  678. the frames at a constant rate the rotation starts slowly, until
  679. at two-thirds (66.666%) of the way through the images have rotated
  680. 180 degrees.  The rotation speeds up so that by the time it hits
  681. finishes (100%), it's completed a full rotation.
  682.  
  683. ----------------------------------------------------------------------
  684. DTA BACKUP.ZIP:FLIC.FLI:20 /CL110,120,90,80 /FT
  685.  
  686. Read frame 20 of a flic that's stored in a ZIP file.
  687. Clip a 90x80-pixel square from location 100,120 of the image
  688. and save it as a TGA file.
  689.  
  690. ======================================================================
  691. Speed concerns:
  692.  
  693.   DTA is fastest when you use grayscale instead of a palette.
  694.  
  695.   If you let DTA generate its own palette, DTA is still
  696.   relatively speedy, except it has to read all the pictures
  697.   first to gather color statistics.  It gets (lots) slower if
  698.   you dither.
  699.  
  700.   If you create an animation from .TGA files stored in an
  701.   archive file (.LZH or .ZIP), then DTA is somewhat slower,
  702.   it takes time to extract the pictures from the archive.
  703.  
  704.   If you average multiple files or rescale pictures, that is
  705.   going to slow things down.
  706.  
  707. ======================================================================
  708. Credits:
  709.  
  710.   To create palettes and select colors from palettes, this
  711.   program uses an algorithm that I found in an article called "A
  712.   Simple Method for Color Quantization:  Octree Quantization," by
  713.   Michael Gervautz and Werner Purgathofer, which can be found in
  714.   a book called "Graphics Gems," edited by Andrew S. Glassner.  I
  715.   recommend this book highly.
  716.  
  717.   The .FLI file format was explained in a document called
  718.   FLIDOC.TXT from Jim Kent's FLILIB.  I wasn't able to use this
  719.   C library in DTA, since I do my coding in Pascal, but the
  720.   document contained all the info I needed.  (Jim Kent is also
  721.   the guy who, with Tom Hudson, wrote TGAFLI, and who developed
  722.   Animator and Animator Pro.)
  723.  
  724.   Thanks to Borland International and TurboPower Software for
  725.   creating some great programming tools.
  726.  
  727.   More thanks to Jim Kent for his info about 640x480 .FLIs on
  728.   BIX.
  729.  
  730.   Thanks to Dan Farmer, Alexander Enzmann, Jeff Bowermaster,
  731.   and others for their excellent suggestions.
  732.  
  733.   Thanks to Dan Farmer for sprucing up this documentation
  734.   file.
  735.  
  736.   Thanks to Tim Wegner for talking me into finally adding GIF89a
  737.   input.
  738.  
  739.   Thanks to the Cafe Pamplona in Harvard Square for being such
  740.   a cool place to swill coffee and discuss ray-tracing and animation.
  741.  
  742. ======================================================================
  743. Disclaimer:
  744.  
  745.   If you use DTA, you do so at your own risk.  I won't be held
  746.   responsible if it screws anything up.  If you don't agree
  747.   to this, then don't use it.
  748.  
  749. ======================================================================
  750. Support:
  751.  
  752.   If you've got any requests/bug reports/suggestions, send a message
  753.   to:
  754.     "David Mason" on "The Graphics Alternative", (510) 524-2780,
  755.     and on "Channel 1" BBS, (617) 354-8873.
  756.     "76546,1321" on Compuserve.
  757.     (I also sometimes check the "You Can Call Me Ray" BBS,
  758.      (708) 358-5611, but not too often these days because of
  759.      communications problems)
  760.  
  761.   You'll probably get some kind of a response (maybe sooner, maybe
  762.   later)
  763.